/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package AplManager.controller;
import AplManager.views.*;
import AplManager.models.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
/**
 *
 * @author user
 */
public class StartingLineUpController {
     private StartingLineUp view;
      //private TableDisplay tableDisplayView;
     private Team model;
    private ActionListener actionListener;
    
    public StartingLineUpController(Team model,StartingLineUp  view){
       this.model = model;
        this.view  = view;
    }
    
    public void control(){        
        actionListener = new ActionListener() {
              @Override
              public void actionPerformed(ActionEvent e) { 
                  if(e.getSource().equals(view.getOkBtn())){
                  //AddPlayer addplayer = new AddPlayer();
                  //addplayer.setVisible(true);
                 view.setVisible(false);
                  }
              }
        };                
        view.getOkBtn().addActionListener(actionListener);
    }
}
